Previous Book Contents Book Index Next

Inside Macintosh: QuickDraw GX Objects /
Chapter 6 - Transform Objects / Transform Objects Reference
Functions / Getting and Setting the View Port List


GXGetShapeViewPorts

You can use the GXGetShapeViewPorts function to retrieve the view port list of the transform object associated with a specific shape.

long GXGetShapeViewPorts(gxShape source, 
                         gxViewPort list[]);
source
A reference to the shape whose transform object contains the view port list you want to examine.
list
An array of view port references. On return, the array contains the view port list of the source shape's transform.
function result
The number of references in the view port list of the source shape's transform.
DESCRIPTION
The GXGetShapeViewPorts function copies references to the view ports associated with the source shape's transform into the array referenced by the list parameter, and returns as the function result the total number of view port references in the list.

If you pass nil for the list parameter, the function returns the number of view ports as the function result, but does not return the references to the view ports. Thus you normally call this function twice: once to determine the size of view port array to allocate, and once to retrieve the array itself.

SPECIAL CONSIDERATIONS
This function returns all view port references in the source transform's view port list, including any invalid ones (for view ports that have been disposed of).

ERRORS, WARNINGS, AND NOTICES
Errors 
out_of_memory 
shape_is_nil 
Notices (debugging version) 
transform_references_disposed_viewPort
SEE ALSO
To assign a view port list to the transform object associated with a specified shape, use the GXSetShapeViewPorts function, described next.

To retrieve the view port list of a transform object, use the GXGetTransformViewPorts function, described on page 6-73.


Previous Book Contents Book Index Next

© Apple Computer, Inc.
7 JUL 1996